package com.homestead.controller.ao;

import cn.hutool.core.bean.BeanUtil;
import com.homestead.bo.CreateOrgBo;
import com.homestead.convert.AbstractConverter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * @author HanBin_Yang
 * @since 2021/4/10 18:23
 */
@ApiModel(value = "创建组织-入参")
@Data
public class CreateOrgAo extends AbstractConverter<CreateOrgBo> {
    @ApiModelProperty(value = "组织名称", required = true, example = "碧桂园13期")
    private String orgName;
    @ApiModelProperty(value = "组织级别 0平台 1集团 2地区公司 3楼盘", required = true, example = "3")
    private Integer orgLevel;
    @ApiModelProperty(value = "组织编码 楼盘对应buildCode")
    private String orgCode;
    @ApiModelProperty(value = "所属组织编码")
    private String parentCode;

    @Override
    public CreateOrgBo convert() {
        CreateOrgBo bo = new CreateOrgBo();
        BeanUtil.copyProperties(this, bo);
        return bo;
    }
}
